package com.ykq.system.controller;

import com.ykq.core.entity.DictData;
import com.ykq.core.vo.R;
import com.ykq.system.service.DictDataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Author: 闫克起
 * @Description:
 * @Date: Create in 9:12 2024/8/14
 */
@RestController
@RequestMapping("/system/dict/data")
public class DictDataController {
    @Autowired
    private DictDataService dictDataService;
    @GetMapping("type/{type}")
    public R<List<DictData>> listByType(@PathVariable String type)
    {
        return dictDataService.selectByType(type);
    }
}
